package com.masterrabbit.controller;

import com.masterrabbit.domain.Packages;
import com.masterrabbit.service.PackagesService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/packages")
public class PackagesController {
    @Autowired
    private PackagesService packagesService;
    @RequestMapping("/serch")
    public List<Packages> serch(Integer merchantId) {
       return packagesService.searchPackages(merchantId);
    }
}
